1. Field of the Invention
The present invention relates to a graphics data generation technology for generating graphics of natural objects, for example, mountain and coastline using computer graphics, and more specifically, to a technique for avoiding unnatural modes when determining the shapes of the above-described graphics using random numbers.
2. Description of the Related Art
In the field of computer graphics, to express natural objects such as mountain and coastline in the most natural possible manner, a shape of a graphics object that varies from one place to another may be determined using random numbers. For example, in a video game, when it is desired to express graphics such as a far mountain behind a moving character in a more natural manner, shapes of parts of the graphics are determined using random numbers.
An example of a graphic shape determining technique using random numbers is a fractal technique. The fractal technique is a technique for obtaining a CG (computer graphics) image by generating fractal graphics inside an information processing apparatus.
Conventionally, a fractal graphics is generated by an information processing apparatus as follows.
First, a plurality of shape specific points is determined to specify the shape of the fractal graphics according to the purpose of software. For example, in the case where a target graphics is a three-dimensional graphics, when projected onto an XY plane in an orthogonal coordinate system made up of the X-axis, Y-axis and Z-axis, each shape specific point is placed at one or a plurality of vertices of a quadrangle.
Once a plurality of shape specific points is determined, then midpoint division is performed. That is, the X and Y coordinate values at a midpoint of each side of a quadrangle when each shape specific point is projected onto the XY plane, and the X and Y coordinate values at a midpoint of a line connecting the midpoint of the mutually facing sides of the quadrangle when projected on the XY plane are calculated. Then, the calculated X and Y coordinate values are determined as X and Y coordinate values of a new changeable shape specific point. Further, random numbers are generated and a Z coordinate value of the new shape specific point is determined using the random numbers generated. Random numbers are values generated according to a random number seed and the random number seed becomes an initial value for calculation of random numbers, and therefore a random number value is determined uniquely according to the random number seed. A random number generated immediately before is used as the random number seed.
The shape of a three-dimensional graphics is determined from the X, Y and Z coordinate values of the new shape specific point obtained in this way and the X, Y and Z coordinate values of a shape specific point placed beforehand, and this is used as the data (“graphics data”) to be expressed on an external display, etc. connected to a computer.
Since the Z coordinate value of the new shape specific point is dependent on random numbers, the graphics expressed by the graphics data generated becomes a fractal graphics.
As described above, a Z coordinate value of a new shape specific point is determined using random numbers. However, since a random number generated immediately before is used as a random number seed, the conventional art involves problems as shown below.
For example, suppose a case where there is a fractal graphics in an image made up of a plurality of blocks shown on a display whose one screen displays only one block of the image and a character appearing in a video game moves within this image. In this case, when the character moves from the currently displayed block to another block, the screen shown on the display changes simultaneously with the movement of the character. A fractal graphics is generated every time the screen on the display is changed, and therefore even if the character arrives at a same point of a certain block after passing through a plurality of blocks, the shape of the graphics may be different depending on the blocks through which the character has passed before arriving at that point (originally, that shape must be identical no matter through what path the character has passed). This is because the conventional art uses a random number generated just before as is as the seed of the random number, which results in a different value depending on the blocks through which the character has passed.
Moreover, when the fractal graphics is expressed across a plurality of blocks as shown above, each fractal graphics is generated independently when the display of each block is changed. For this reason, succession of graphics from one block to another on the border of blocks may not take place smoothly.
Such a problem is not limited to fractal graphics alone but is common to all cases where graphics are formed whose shape specific points are determined using random numbers.